const express = require('express')
const app = express()
const port = 9001

const user = require('./server/user.js')

app.get('/user', (req, res) => {
  console.log(req.query)
  const userInfo = user.getUserInfo()
  api.JsonData(res, 200, userInfo)
})

app.listen(port, () => {
  console.log(`端口${port} 已启动服务`)
})

exports.app = app